<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<form id="mainform" name=frm method=post action="">
    <table width = 100% id="id-form">
        <tr>
            <td nowrap="nowrap" valign=top>
                Nhập mã sách
            </td>
            <td >
                <input type=text class=inputbox name=MA value="<??>" size=25>
            </td>
        </tr>
        <tr style="margin-top: 10px">
            <td nowrap="nowrap"></td>
            <td margin-top: 10px nowrap="nowrap" colspan="3"><input type=submit value="Tìm kiếm">
                    <!-- <input type=submit value="Tìm lại"> -->
            </td>
        </tr>
    </table >
    <table style="margin-top: 10px" border="0" width="100%" cellpadding="0" cellspacing="0" id="product-table">
        <thead>
            <tr class="alternate-row">
                <th style="text-align: center">STT</th>
                <th style="text-align: center">
                    <input type=checkbox name=DELALL onclick="SelectAll(this,'DEL')">
                </th>
                <th width="" style="text-align: left">Mã sách</th>
                <th width="" style="text-align: left">Tên sách</th>
                <th width="" style="text-align: left">Quyển số</th>
                <th width="" style="text-align: left">Người mượn</th>
                <th width="" style="text-align: left">Ngày trả</th>
            </tr>
        </thead>
        <tfoot>
        </tfoot>
        <tbody>
            <?php
            $dt = $this->data;
            if(count($dt)==0){
		echo "<tr><td colspan=9>Không có dữ liệu nào được tìm thấy</td></tr>";
            } else {
                $stt = 1;
            //var_dump($this->data);exit;
            foreach($dt as $item){?>
            <tr>
                <td><?=$stt?></td>
                <td>
                    <input type="checkbox" name="DEL[]" value="<?=$item['ID']?>" />
                </td>
                <td><?php echo $item['MASACH'];?></td>
                <td><?php echo $item['TENSACH'];?></td>
                <td> <?=$item['QUYEN_SO'];?></td>
                <td> <?=$item['TEN_NGUOI_MUON'];?></td>
                <td> <?=$item['NGAY_TRA'];?></td>
            </tr>
            <?php $stt++;}}?>
        </tbody>
    </table>
</form>